<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.9.1"/>
<title>opennars: aruntime/src/main/java/nars/inference/LocalRules.java Source File</title>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../jquery.js"></script>
<script type="text/javascript" src="../../dynsections.js"></script>
<link href="../../navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../resize.js"></script>
<script type="text/javascript" src="../../navtreedata.js"></script>
<script type="text/javascript" src="../../navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../search/searchdata.js"></script>
<script type="text/javascript" src="../../search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">opennars
   &#160;<span id="projectnumber">1.5.5</span>
   </div>
   <div id="projectbrief">1.5-ish</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.9.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="../../index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="../../pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="../../namespaces.html"><span>Packages</span></a></li>
      <li><a href="../../annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="../../files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="../../search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="../../search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="../../files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('d0/db7/LocalRules_8java_source.html','../../');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="headertitle">
<div class="title">LocalRules.java</div>  </div>
</div><!--header-->
<div class="contents">
<a href="../../d0/db7/LocalRules_8java.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">/*</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment"> * LocalRules.java</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"> * Copyright (C) 2008  Pei Wang</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="comment"> * This file is part of Open-NARS.</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="comment"> * Open-NARS is free software; you can redistribute it and/or modify</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="comment"> * it under the terms of the GNU General Public License as published by</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="comment"> * the Free Software Foundation, either version 2 of the License, or</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="comment"> * (at your option) any later version.</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="comment"> * Open-NARS is distributed in the hope that it will be useful,</span></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="comment"> * but WITHOUT ANY WARRANTY; without even the abduction warranty of</span></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="comment"> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span></div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="comment"> * GNU General Public License for more details.</span></div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="comment"> * You should have received a copy of the GNU General Public License</span></div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;<span class="comment"> * along with Open-NARS.  If not, see &lt;http://www.gnu.org/licenses/&gt;.</span></div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;<span class="keyword">package </span>nars.inference;</div>
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;</div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;<span class="keyword">import</span> <a class="code" href="../../d7/d81/namespacenars.html">nars</a>.<a class="code" href="../../de/ddc/namespacenars_1_1storage.html">storage</a>.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a>;</div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;<span class="keyword">import</span> <a class="code" href="../../d7/d81/namespacenars.html">nars</a>.<a class="code" href="../../db/dec/namespacenars_1_1entity.html">entity</a>.*;</div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;<span class="keyword">import</span> <a class="code" href="../../d7/d81/namespacenars.html">nars</a>.<a class="code" href="../../d0/d72/namespacenars_1_1language.html">language</a>.*;</div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;<span class="keyword">import</span> <a class="code" href="../../d7/d81/namespacenars.html">nars</a>.<a class="code" href="../../db/d64/namespacenars_1_1io.html">io</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>;</div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;</div>
<div class="line"><a name="l00038"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules.html">   38</a></span>&#160;<span class="keyword">public</span> <span class="keyword">class </span><a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules.html">LocalRules</a> {</div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;</div>
<div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;    <span class="comment">/* -------------------- same contents -------------------- */</span></div>
<div class="line"><a name="l00053"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_aac1c92950f50edd04d12229a8c992987.html#aac1c92950f50edd04d12229a8c992987">   53</a></span>&#160;    <span class="keyword">public</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_aac1c92950f50edd04d12229a8c992987.html#aac1c92950f50edd04d12229a8c992987">match</a>(<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task.html">Task</a> task, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sentence = (<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a>) task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>().<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a721f626ab83f34dc2e6858a4eede7102.html#a721f626ab83f34dc2e6858a4eede7102">clone</a>();</div>
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;        <span class="keywordflow">if</span> (sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a7d95d60caaf4c895559182a7eb2ff71e.html#a7d95d60caaf4c895559182a7eb2ff71e">isJudgment</a>()) {</div>
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;            <span class="keywordflow">if</span> (<a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a21cfc2af8051142d084776d0bbc618e6.html#a21cfc2af8051142d084776d0bbc618e6">revisible</a>(sentence, belief)) {</div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;                <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a40edb0903d098da966e3ef972e5c8abd.html#a40edb0903d098da966e3ef972e5c8abd">revision</a>(sentence, belief, <span class="keyword">true</span>, memory);</div>
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;            }</div>
<div class="line"><a name="l00059"></a><span class="lineno">   59</span>&#160;        } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable.html">Variable</a>.<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable_a2770bbc76b3aac48f49a1c15aaedab1b.html#a2770bbc76b3aac48f49a1c15aaedab1b">unify</a>(<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols_a9ff625a6eaec1b710eaec490ee8fc549.html#a9ff625a6eaec1b710eaec490ee8fc549">VAR_QUERY</a>, sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>(),</div>
<div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;                (<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a>) belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>().<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_ae2dba162b71bb9b806f54832249a260c.html#ae2dba162b71bb9b806f54832249a260c">clone</a>())) {</div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;            <span class="comment">// trySolution(sentence, belief, task, memory);</span></div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;            <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a3ecf859c238ad7f0c44c45e3e5df0081.html#a3ecf859c238ad7f0c44c45e3e5df0081">trySolution</a>(belief, task, memory);</div>
<div class="line"><a name="l00063"></a><span class="lineno">   63</span>&#160;        }</div>
<div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;    }</div>
<div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;</div>
<div class="line"><a name="l00075"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a21cfc2af8051142d084776d0bbc618e6.html#a21cfc2af8051142d084776d0bbc618e6">   75</a></span>&#160;    <span class="keyword">public</span> <span class="keyword">static</span> <span class="keywordtype">boolean</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a21cfc2af8051142d084776d0bbc618e6.html#a21cfc2af8051142d084776d0bbc618e6">revisible</a>(<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> s1, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> s2) {</div>
<div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;        <span class="keywordflow">return</span> (s1.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>().<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f.html#ad85f45a7858737445d5158801774ff5f">equals</a>(s2.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>()) &amp;&amp; s1.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ae57a195c3623dc9b8245d977adc94b4d.html#ae57a195c3623dc9b8245d977adc94b4d">getRevisible</a>());</div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;    }</div>
<div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160;</div>
<div class="line"><a name="l00093"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a40edb0903d098da966e3ef972e5c8abd.html#a40edb0903d098da966e3ef972e5c8abd">   93</a></span>&#160;    <span class="keyword">public</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a40edb0903d098da966e3ef972e5c8abd.html#a40edb0903d098da966e3ef972e5c8abd">revision</a>(<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> newBelief, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> oldBelief,</div>
<div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160;            <span class="keywordtype">boolean</span> feedbackToLinks, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> newTruth = newBelief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> oldTruth = oldBelief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a22620614c797410623291399bae01a0b.html#a22620614c797410623291399bae01a0b">revision</a>(newTruth, oldTruth);</div>
<div class="line"><a name="l00098"></a><span class="lineno">   98</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac5e336432ebc7744461334f04bfd5216.html#ac5e336432ebc7744461334f04bfd5216">revise</a>(newTruth, oldTruth, truth,</div>
<div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;                feedbackToLinks, memory);</div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> content = newBelief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00101"></a><span class="lineno">  101</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160;    }</div>
<div class="line"><a name="l00103"></a><span class="lineno">  103</span>&#160;</div>
<div class="line"><a name="l00116"></a><span class="lineno">  116</span>&#160;    <span class="comment">// public static void trySolution(Sentence problem, Sentence belief, Task</span></div>
<div class="line"><a name="l00117"></a><span class="lineno">  117</span>&#160;    <span class="comment">// task, Memory memory) {</span></div>
<div class="line"><a name="l00118"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a3ecf859c238ad7f0c44c45e3e5df0081.html#a3ecf859c238ad7f0c44c45e3e5df0081">  118</a></span>&#160;    <span class="keyword">public</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a3ecf859c238ad7f0c44c45e3e5df0081.html#a3ecf859c238ad7f0c44c45e3e5df0081">trySolution</a>(<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief, <a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task.html">Task</a> task, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00119"></a><span class="lineno">  119</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> problem = task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>();</div>
<div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> oldBest = task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_a63d100ab04dafaea220b3c1125b782e6.html#a63d100ab04dafaea220b3c1125b782e6">getBestSolution</a>();</div>
<div class="line"><a name="l00121"></a><span class="lineno">  121</span>&#160;        <span class="keywordtype">float</span> newQ = <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a91eadfda9f647cd8e799b4f982e14fca.html#a91eadfda9f647cd8e799b4f982e14fca">solutionQuality</a>(problem, belief);</div>
<div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160;        <span class="keywordflow">if</span> (oldBest != null) {</div>
<div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160;            <span class="keywordtype">float</span> oldQ = <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a91eadfda9f647cd8e799b4f982e14fca.html#a91eadfda9f647cd8e799b4f982e14fca">solutionQuality</a>(problem, oldBest);</div>
<div class="line"><a name="l00124"></a><span class="lineno">  124</span>&#160;            <span class="keywordflow">if</span> (oldQ &gt;= newQ) {</div>
<div class="line"><a name="l00125"></a><span class="lineno">  125</span>&#160;                <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160;            }</div>
<div class="line"><a name="l00127"></a><span class="lineno">  127</span>&#160;        }</div>
<div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160;        task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_a7d956def715a678d75b113f4bf5efa1d.html#a7d956def715a678d75b113f4bf5efa1d">setBestSolution</a>(belief);</div>
<div class="line"><a name="l00129"></a><span class="lineno">  129</span>&#160;        <span class="keywordflow">if</span> (task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_a0dfdf9a597e57b5cf70d88f954ac7a3f.html#a0dfdf9a597e57b5cf70d88f954ac7a3f">isInput</a>()) { <span class="comment">// moved from Sentence</span></div>
<div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;            memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26cbb4acec5bb2c23a048d7deba4051d.html#a26cbb4acec5bb2c23a048d7deba4051d">report</a>(belief, <span class="keyword">false</span>);</div>
<div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160;        }</div>
<div class="line"><a name="l00132"></a><span class="lineno">  132</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ad2933ccc8d786f0cea9d8f561814cbf9.html#ad2933ccc8d786f0cea9d8f561814cbf9">solutionEval</a>(problem, belief,</div>
<div class="line"><a name="l00133"></a><span class="lineno">  133</span>&#160;                task, memory);</div>
<div class="line"><a name="l00134"></a><span class="lineno">  134</span>&#160;        <span class="keywordflow">if</span> ((budget != null) &amp;&amp; budget.<a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue_ae83b822f3bab4c1831e94d72fc770f58.html#ae83b822f3bab4c1831e94d72fc770f58">aboveThreshold</a>()) {</div>
<div class="line"><a name="l00135"></a><span class="lineno">  135</span>&#160;            memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aa0cec63b98350a34c10513f3efeaff86.html#aa0cec63b98350a34c10513f3efeaff86">activatedTask</a>(budget, belief, task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ae0fc96866e544c3dda5a87ea5c806fc3.html#ae0fc96866e544c3dda5a87ea5c806fc3">getParentBelief</a>());</div>
<div class="line"><a name="l00136"></a><span class="lineno">  136</span>&#160;        }</div>
<div class="line"><a name="l00137"></a><span class="lineno">  137</span>&#160;    }</div>
<div class="line"><a name="l00138"></a><span class="lineno">  138</span>&#160;</div>
<div class="line"><a name="l00148"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a91eadfda9f647cd8e799b4f982e14fca.html#a91eadfda9f647cd8e799b4f982e14fca">  148</a></span>&#160;    <span class="keyword">public</span> <span class="keyword">static</span> <span class="keywordtype">float</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a91eadfda9f647cd8e799b4f982e14fca.html#a91eadfda9f647cd8e799b4f982e14fca">solutionQuality</a>(<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> problem, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> solution) {</div>
<div class="line"><a name="l00149"></a><span class="lineno">  149</span>&#160;        <span class="keywordflow">if</span> (problem == null) {</div>
<div class="line"><a name="l00150"></a><span class="lineno">  150</span>&#160;            <span class="keywordflow">return</span> solution.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>().<a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue_aa5ffcde3ae611b087ba7fdd4cd67b216.html#aa5ffcde3ae611b087ba7fdd4cd67b216">getExpectation</a>();</div>
<div class="line"><a name="l00151"></a><span class="lineno">  151</span>&#160;        }</div>
<div class="line"><a name="l00152"></a><span class="lineno">  152</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = solution.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00153"></a><span class="lineno">  153</span>&#160;        <span class="keywordflow">if</span> (problem.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a3664d0b53eca935536d60cd0e3a13256.html#a3664d0b53eca935536d60cd0e3a13256">containQueryVar</a>()) { <span class="comment">// &quot;yes/no&quot; question</span></div>
<div class="line"><a name="l00154"></a><span class="lineno">  154</span>&#160;            <span class="keywordflow">return</span> truth.<a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue_aa5ffcde3ae611b087ba7fdd4cd67b216.html#aa5ffcde3ae611b087ba7fdd4cd67b216">getExpectation</a>()</div>
<div class="line"><a name="l00155"></a><span class="lineno">  155</span>&#160;                    / solution.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>().<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_ae14632d1d25bcde8d6698ea0b58eb19a.html#ae14632d1d25bcde8d6698ea0b58eb19a">getComplexity</a>();</div>
<div class="line"><a name="l00156"></a><span class="lineno">  156</span>&#160;        } <span class="keywordflow">else</span> { <span class="comment">// &quot;what&quot; question or goal</span></div>
<div class="line"><a name="l00157"></a><span class="lineno">  157</span>&#160;            <span class="keywordflow">return</span> truth.<a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue_a68ca7d92e9ea20d2a9a9f578ad7b681c.html#a68ca7d92e9ea20d2a9a9f578ad7b681c">getConfidence</a>();</div>
<div class="line"><a name="l00158"></a><span class="lineno">  158</span>&#160;        }</div>
<div class="line"><a name="l00159"></a><span class="lineno">  159</span>&#160;    }</div>
<div class="line"><a name="l00160"></a><span class="lineno">  160</span>&#160;</div>
<div class="line"><a name="l00161"></a><span class="lineno">  161</span>&#160;    <span class="comment">/*</span></div>
<div class="line"><a name="l00162"></a><span class="lineno">  162</span>&#160;<span class="comment">     * -------------------- same terms, difference relations</span></div>
<div class="line"><a name="l00163"></a><span class="lineno">  163</span>&#160;<span class="comment">     * --------------------</span></div>
<div class="line"><a name="l00164"></a><span class="lineno">  164</span>&#160;<span class="comment">     */</span></div>
<div class="line"><a name="l00171"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a93af32adec92cf57671c32e9ccc2dffc.html#a93af32adec92cf57671c32e9ccc2dffc">  171</a></span>&#160;    <span class="keyword">public</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a93af32adec92cf57671c32e9ccc2dffc.html#a93af32adec92cf57671c32e9ccc2dffc">matchReverse</a>(<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00172"></a><span class="lineno">  172</span>&#160;        <a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task.html">Task</a> task = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>();</div>
<div class="line"><a name="l00173"></a><span class="lineno">  173</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">getCurrentBelief</a>();</div>
<div class="line"><a name="l00174"></a><span class="lineno">  174</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sentence = task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>();</div>
<div class="line"><a name="l00175"></a><span class="lineno">  175</span>&#160;        <span class="keywordflow">if</span> (sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a7d95d60caaf4c895559182a7eb2ff71e.html#a7d95d60caaf4c895559182a7eb2ff71e">isJudgment</a>()) {</div>
<div class="line"><a name="l00176"></a><span class="lineno">  176</span>&#160;            <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a4e1558986087d2202179074a3ae76ca4.html#a4e1558986087d2202179074a3ae76ca4">inferToSym</a>((<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a>) sentence, belief, memory);</div>
<div class="line"><a name="l00177"></a><span class="lineno">  177</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00178"></a><span class="lineno">  178</span>&#160;            <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_aeb46ba9d63958c022519607076ce1273.html#aeb46ba9d63958c022519607076ce1273">conversion</a>(memory);</div>
<div class="line"><a name="l00179"></a><span class="lineno">  179</span>&#160;        }</div>
<div class="line"><a name="l00180"></a><span class="lineno">  180</span>&#160;    }</div>
<div class="line"><a name="l00181"></a><span class="lineno">  181</span>&#160;</div>
<div class="line"><a name="l00194"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a2a6db5879fbb7ba315891fa9d49c985b.html#a2a6db5879fbb7ba315891fa9d49c985b">  194</a></span>&#160;    <span class="keyword">public</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a2a6db5879fbb7ba315891fa9d49c985b.html#a2a6db5879fbb7ba315891fa9d49c985b">matchAsymSym</a>(<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> asym, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sym, <span class="keywordtype">int</span> figure,</div>
<div class="line"><a name="l00195"></a><span class="lineno">  195</span>&#160;            <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00196"></a><span class="lineno">  196</span>&#160;        <span class="keywordflow">if</span> (memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>().<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>().<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a7d95d60caaf4c895559182a7eb2ff71e.html#a7d95d60caaf4c895559182a7eb2ff71e">isJudgment</a>()) {</div>
<div class="line"><a name="l00197"></a><span class="lineno">  197</span>&#160;            <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_ada47dcf3767d0fb0dc24b00872edf8b3.html#ada47dcf3767d0fb0dc24b00872edf8b3">inferToAsym</a>((<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a>) asym, (<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a>) sym, memory);</div>
<div class="line"><a name="l00198"></a><span class="lineno">  198</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00199"></a><span class="lineno">  199</span>&#160;            <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_ae878f1b2fff31ef78b7916bde1b939b3.html#ae878f1b2fff31ef78b7916bde1b939b3">convertRelation</a>(memory);</div>
<div class="line"><a name="l00200"></a><span class="lineno">  200</span>&#160;        }</div>
<div class="line"><a name="l00201"></a><span class="lineno">  201</span>&#160;    }</div>
<div class="line"><a name="l00202"></a><span class="lineno">  202</span>&#160;</div>
<div class="line"><a name="l00203"></a><span class="lineno">  203</span>&#160;    <span class="comment">/* -------------------- two-premise inference rules -------------------- */</span></div>
<div class="line"><a name="l00217"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a4e1558986087d2202179074a3ae76ca4.html#a4e1558986087d2202179074a3ae76ca4">  217</a></span>&#160;    <span class="keyword">private</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a4e1558986087d2202179074a3ae76ca4.html#a4e1558986087d2202179074a3ae76ca4">inferToSym</a>(<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> judgment1, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> judgment2,</div>
<div class="line"><a name="l00218"></a><span class="lineno">  218</span>&#160;            <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00219"></a><span class="lineno">  219</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> s1 = (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) judgment1.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00220"></a><span class="lineno">  220</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> t1 = s1.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5.html#ace4f80751d303c613e467163913bebf5">getSubject</a>();</div>
<div class="line"><a name="l00221"></a><span class="lineno">  221</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> t2 = s1.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0.html#ababe6155e2f78e769f76493317e118e0">getPredicate</a>();</div>
<div class="line"><a name="l00222"></a><span class="lineno">  222</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> content;</div>
<div class="line"><a name="l00223"></a><span class="lineno">  223</span>&#160;        <span class="keywordflow">if</span> (s1 instanceof <a class="code" href="../../d0/df3/classnars_1_1language_1_1Inheritance.html">Inheritance</a>) {</div>
<div class="line"><a name="l00224"></a><span class="lineno">  224</span>&#160;            content = <a class="code" href="../../d3/d1f/classnars_1_1language_1_1Similarity.html">Similarity</a>.<a class="code" href="../../d3/d1f/classnars_1_1language_1_1Similarity_ae72436d78c25d4735b4201d773dd1901.html#ae72436d78c25d4735b4201d773dd1901">make</a>(t1, t2, memory);</div>
<div class="line"><a name="l00225"></a><span class="lineno">  225</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00226"></a><span class="lineno">  226</span>&#160;            content = <a class="code" href="../../d1/d8b/classnars_1_1language_1_1Equivalence.html">Equivalence</a>.<a class="code" href="../../d1/d8b/classnars_1_1language_1_1Equivalence_ad5069483330bc875fbb48a1e992f7bf7.html#ad5069483330bc875fbb48a1e992f7bf7">make</a>(t1, t2, memory);</div>
<div class="line"><a name="l00227"></a><span class="lineno">  227</span>&#160;        }</div>
<div class="line"><a name="l00228"></a><span class="lineno">  228</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> value1 = judgment1.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00229"></a><span class="lineno">  229</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> value2 = judgment2.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00230"></a><span class="lineno">  230</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a20446cf012806110b595d9d1309bba24.html#a20446cf012806110b595d9d1309bba24">intersection</a>(value1, value2);</div>
<div class="line"><a name="l00231"></a><span class="lineno">  231</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00232"></a><span class="lineno">  232</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00233"></a><span class="lineno">  233</span>&#160;    }</div>
<div class="line"><a name="l00234"></a><span class="lineno">  234</span>&#160;</div>
<div class="line"><a name="l00248"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_ada47dcf3767d0fb0dc24b00872edf8b3.html#ada47dcf3767d0fb0dc24b00872edf8b3">  248</a></span>&#160;    <span class="keyword">private</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_ada47dcf3767d0fb0dc24b00872edf8b3.html#ada47dcf3767d0fb0dc24b00872edf8b3">inferToAsym</a>(<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> asym, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sym, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00249"></a><span class="lineno">  249</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> statement = (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) asym.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00250"></a><span class="lineno">  250</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> sub = statement.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0.html#ababe6155e2f78e769f76493317e118e0">getPredicate</a>();</div>
<div class="line"><a name="l00251"></a><span class="lineno">  251</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> pre = statement.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5.html#ace4f80751d303c613e467163913bebf5">getSubject</a>();</div>
<div class="line"><a name="l00252"></a><span class="lineno">  252</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> content = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(statement, sub, pre, memory);</div>
<div class="line"><a name="l00253"></a><span class="lineno">  253</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ae8945611915519f50ab3392c9168b170.html#ae8945611915519f50ab3392c9168b170">reduceConjunction</a>(sym.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>(),</div>
<div class="line"><a name="l00254"></a><span class="lineno">  254</span>&#160;                asym.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>());</div>
<div class="line"><a name="l00255"></a><span class="lineno">  255</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00256"></a><span class="lineno">  256</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00257"></a><span class="lineno">  257</span>&#160;    }</div>
<div class="line"><a name="l00258"></a><span class="lineno">  258</span>&#160;</div>
<div class="line"><a name="l00259"></a><span class="lineno">  259</span>&#160;    <span class="comment">/* -------------------- one-premise inference rules -------------------- */</span></div>
<div class="line"><a name="l00269"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_aeb46ba9d63958c022519607076ce1273.html#aeb46ba9d63958c022519607076ce1273">  269</a></span>&#160;    <span class="keyword">private</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_aeb46ba9d63958c022519607076ce1273.html#aeb46ba9d63958c022519607076ce1273">conversion</a>(<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00270"></a><span class="lineno">  270</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a3a5a75db35145955b00958489a5ce50d.html#a3a5a75db35145955b00958489a5ce50d">conversion</a>(memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">getCurrentBelief</a>()</div>
<div class="line"><a name="l00271"></a><span class="lineno">  271</span>&#160;                .<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>());</div>
<div class="line"><a name="l00272"></a><span class="lineno">  272</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00273"></a><span class="lineno">  273</span>&#160;        <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a19ea934d3f2b6eb6a01f09db55afb4f0.html#a19ea934d3f2b6eb6a01f09db55afb4f0">convertedJudgment</a>(truth, budget, memory);</div>
<div class="line"><a name="l00274"></a><span class="lineno">  274</span>&#160;    }</div>
<div class="line"><a name="l00275"></a><span class="lineno">  275</span>&#160;</div>
<div class="line"><a name="l00283"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_ae878f1b2fff31ef78b7916bde1b939b3.html#ae878f1b2fff31ef78b7916bde1b939b3">  283</a></span>&#160;    <span class="keyword">private</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_ae878f1b2fff31ef78b7916bde1b939b3.html#ae878f1b2fff31ef78b7916bde1b939b3">convertRelation</a>(<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00284"></a><span class="lineno">  284</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">getCurrentBelief</a>().<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00285"></a><span class="lineno">  285</span>&#160;        <span class="keywordflow">if</span> (((<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>().<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_a091f9ec3bdacfd6741f767cb62b14c0f.html#a091f9ec3bdacfd6741f767cb62b14c0f">getContent</a>()).isCommutative()) {</div>
<div class="line"><a name="l00286"></a><span class="lineno">  286</span>&#160;            truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b.html#ab001ba72b5926188d21dd48a5eaaeb8b">abduction</a>(truth, 1.0f);</div>
<div class="line"><a name="l00287"></a><span class="lineno">  287</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00288"></a><span class="lineno">  288</span>&#160;            truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_af0cd0f846c8a7e500840b517ab006b94.html#af0cd0f846c8a7e500840b517ab006b94">deduction</a>(truth, 1.0f);</div>
<div class="line"><a name="l00289"></a><span class="lineno">  289</span>&#160;        }</div>
<div class="line"><a name="l00290"></a><span class="lineno">  290</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00291"></a><span class="lineno">  291</span>&#160;        <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a19ea934d3f2b6eb6a01f09db55afb4f0.html#a19ea934d3f2b6eb6a01f09db55afb4f0">convertedJudgment</a>(truth, budget, memory);</div>
<div class="line"><a name="l00292"></a><span class="lineno">  292</span>&#160;    }</div>
<div class="line"><a name="l00293"></a><span class="lineno">  293</span>&#160;</div>
<div class="line"><a name="l00306"></a><span class="lineno"><a class="line" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a19ea934d3f2b6eb6a01f09db55afb4f0.html#a19ea934d3f2b6eb6a01f09db55afb4f0">  306</a></span>&#160;    <span class="keyword">private</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a19ea934d3f2b6eb6a01f09db55afb4f0.html#a19ea934d3f2b6eb6a01f09db55afb4f0">convertedJudgment</a>(<a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> newTruth,</div>
<div class="line"><a name="l00307"></a><span class="lineno">  307</span>&#160;            <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> newBudget, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00308"></a><span class="lineno">  308</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> content = (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>().<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_a091f9ec3bdacfd6741f767cb62b14c0f.html#a091f9ec3bdacfd6741f767cb62b14c0f">getContent</a>();</div>
<div class="line"><a name="l00309"></a><span class="lineno">  309</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> beliefContent = (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">getCurrentBelief</a>()</div>
<div class="line"><a name="l00310"></a><span class="lineno">  310</span>&#160;                .<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00311"></a><span class="lineno">  311</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> subjT = content.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5.html#ace4f80751d303c613e467163913bebf5">getSubject</a>();</div>
<div class="line"><a name="l00312"></a><span class="lineno">  312</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> predT = content.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0.html#ababe6155e2f78e769f76493317e118e0">getPredicate</a>();</div>
<div class="line"><a name="l00313"></a><span class="lineno">  313</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> subjB = beliefContent.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5.html#ace4f80751d303c613e467163913bebf5">getSubject</a>();</div>
<div class="line"><a name="l00314"></a><span class="lineno">  314</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> predB = beliefContent.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0.html#ababe6155e2f78e769f76493317e118e0">getPredicate</a>();</div>
<div class="line"><a name="l00315"></a><span class="lineno">  315</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> otherTerm;</div>
<div class="line"><a name="l00316"></a><span class="lineno">  316</span>&#160;        <span class="keywordflow">if</span> (<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable.html">Variable</a>.<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable_a25dcc4d5882131d679903f93d41420c9.html#a25dcc4d5882131d679903f93d41420c9">containVarQuery</a>(subjT.<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_a3aad4654016b8615fd4fa8a26668e1db.html#a3aad4654016b8615fd4fa8a26668e1db">getName</a>())) {</div>
<div class="line"><a name="l00317"></a><span class="lineno">  317</span>&#160;            otherTerm = (predT.<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f.html#ad85f45a7858737445d5158801774ff5f">equals</a>(subjB)) ? predB : subjB;</div>
<div class="line"><a name="l00318"></a><span class="lineno">  318</span>&#160;            content = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(content, otherTerm, predT, memory);</div>
<div class="line"><a name="l00319"></a><span class="lineno">  319</span>&#160;        }</div>
<div class="line"><a name="l00320"></a><span class="lineno">  320</span>&#160;        <span class="keywordflow">if</span> (<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable.html">Variable</a>.<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable_a25dcc4d5882131d679903f93d41420c9.html#a25dcc4d5882131d679903f93d41420c9">containVarQuery</a>(predT.<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_a3aad4654016b8615fd4fa8a26668e1db.html#a3aad4654016b8615fd4fa8a26668e1db">getName</a>())) {</div>
<div class="line"><a name="l00321"></a><span class="lineno">  321</span>&#160;            otherTerm = (subjT.<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f.html#ad85f45a7858737445d5158801774ff5f">equals</a>(subjB)) ? predB : subjB;</div>
<div class="line"><a name="l00322"></a><span class="lineno">  322</span>&#160;            content = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(content, subjT, otherTerm, memory);</div>
<div class="line"><a name="l00323"></a><span class="lineno">  323</span>&#160;        }</div>
<div class="line"><a name="l00324"></a><span class="lineno">  324</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aec1106814819aa1c8437001c2c4bf1a3.html#aec1106814819aa1c8437001c2c4bf1a3">singlePremiseTask</a>(content, <a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols_a13b034b1bca44b2f3d3c8de6d1607047.html#a13b034b1bca44b2f3d3c8de6d1607047">JUDGMENT_MARK</a>, newTruth,</div>
<div class="line"><a name="l00325"></a><span class="lineno">  325</span>&#160;                newBudget);</div>
<div class="line"><a name="l00326"></a><span class="lineno">  326</span>&#160;    }</div>
<div class="line"><a name="l00327"></a><span class="lineno">  327</span>&#160;}</div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9_html_a9f69b4fef64c81abad21404946cd41f9"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">nars.entity.Sentence.getTruth</a></div><div class="ttdeci">TruthValue getTruth()</div><div class="ttdoc">Get the truth value of the sentence. </div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00165">Sentence.java:165</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1BudgetFunctions_ad2933ccc8d786f0cea9d8f561814cbf9_html_ad2933ccc8d786f0cea9d8f561814cbf9"><div class="ttname"><a href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ad2933ccc8d786f0cea9d8f561814cbf9.html#ad2933ccc8d786f0cea9d8f561814cbf9">nars.inference.BudgetFunctions.solutionEval</a></div><div class="ttdeci">static BudgetValue solutionEval(Sentence problem, Sentence solution, Task task, Memory memory)</div><div class="ttdoc">Evaluate the quality of a belief as a solution to a problem, then reward the belief and de-prioritize...</div><div class="ttdef"><b>Definition:</b> <a href="../../de/d4e/BudgetFunctions_8java_source.html#l00081">BudgetFunctions.java:81</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b_html_ab001ba72b5926188d21dd48a5eaaeb8b"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b.html#ab001ba72b5926188d21dd48a5eaaeb8b">nars.inference.TruthFunctions.abduction</a></div><div class="ttdeci">static TruthValue abduction(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<S ==> M>, </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00183">TruthFunctions.java:183</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Term_a3aad4654016b8615fd4fa8a26668e1db_html_a3aad4654016b8615fd4fa8a26668e1db"><div class="ttname"><a href="../../d8/db8/classnars_1_1language_1_1Term_a3aad4654016b8615fd4fa8a26668e1db.html#a3aad4654016b8615fd4fa8a26668e1db">nars.language.Term.getName</a></div><div class="ttdeci">String getName()</div><div class="ttdoc">Reporting the name of the current Term. </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/df2/Term_8java_source.html#l00068">Term.java:68</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0_html_ababe6155e2f78e769f76493317e118e0"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0.html#ababe6155e2f78e769f76493317e118e0">nars.language.Statement.getPredicate</a></div><div class="ttdeci">Term getPredicate()</div><div class="ttdoc">Return the second component of the statement. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00237">Statement.java:237</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_a3a5a75db35145955b00958489a5ce50d_html_a3a5a75db35145955b00958489a5ce50d"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a3a5a75db35145955b00958489a5ce50d.html#a3a5a75db35145955b00958489a5ce50d">nars.inference.TruthFunctions.conversion</a></div><div class="ttdeci">static TruthValue conversion(TruthValue v1)</div><div class="ttdoc">{<A ==> B>} |- <B ==> A> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00038">TruthFunctions.java:38</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_a40edb0903d098da966e3ef972e5c8abd_html_a40edb0903d098da966e3ef972e5c8abd"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a40edb0903d098da966e3ef972e5c8abd.html#a40edb0903d098da966e3ef972e5c8abd">nars.inference.LocalRules.revision</a></div><div class="ttdeci">static void revision(Sentence newBelief, Sentence oldBelief, boolean feedbackToLinks, Memory memory)</div><div class="ttdoc">Belief revision. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00093">LocalRules.java:93</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Inheritance_html"><div class="ttname"><a href="../../d0/df3/classnars_1_1language_1_1Inheritance.html">nars.language.Inheritance</a></div><div class="ttdoc">A Statement about an Inheritance relation. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/d17/Inheritance_8java_source.html#l00031">Inheritance.java:31</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_a20446cf012806110b595d9d1309bba24_html_a20446cf012806110b595d9d1309bba24"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a20446cf012806110b595d9d1309bba24.html#a20446cf012806110b595d9d1309bba24">nars.inference.TruthFunctions.intersection</a></div><div class="ttdeci">static TruthValue intersection(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<M --> S>, <M <-> P>} |- <M --> (S&P)> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00374">TruthFunctions.java:374</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_html"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">nars.inference.TruthFunctions</a></div><div class="ttdoc">All truth-value (and desire-value) functions used in inference rules. </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00028">TruthFunctions.java:28</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_a19ea934d3f2b6eb6a01f09db55afb4f0_html_a19ea934d3f2b6eb6a01f09db55afb4f0"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a19ea934d3f2b6eb6a01f09db55afb4f0.html#a19ea934d3f2b6eb6a01f09db55afb4f0">nars.inference.LocalRules.convertedJudgment</a></div><div class="ttdeci">static void convertedJudgment(TruthValue newTruth, BudgetValue newBudget, Memory memory)</div><div class="ttdoc">Convert jusgment into different relation. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00306">LocalRules.java:306</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Task_a7d956def715a678d75b113f4bf5efa1d_html_a7d956def715a678d75b113f4bf5efa1d"><div class="ttname"><a href="../../dc/ddc/classnars_1_1entity_1_1Task_a7d956def715a678d75b113f4bf5efa1d.html#a7d956def715a678d75b113f4bf5efa1d">nars.entity.Task.setBestSolution</a></div><div class="ttdeci">void setBestSolution(Sentence judg)</div><div class="ttdoc">Set the best-so-far solution for a Question or Goal, and report answer for input question. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d10/Task_8java_source.html#l00167">Task.java:167</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_a2a6db5879fbb7ba315891fa9d49c985b_html_a2a6db5879fbb7ba315891fa9d49c985b"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a2a6db5879fbb7ba315891fa9d49c985b.html#a2a6db5879fbb7ba315891fa9d49c985b">nars.inference.LocalRules.matchAsymSym</a></div><div class="ttdeci">static void matchAsymSym(Sentence asym, Sentence sym, int figure, Memory memory)</div><div class="ttdoc">Inheritance/Implication matches Similarity/Equivalence. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00194">LocalRules.java:194</a></div></div>
<div class="ttc" id="namespacenars_1_1entity_html"><div class="ttname"><a href="../../db/dec/namespacenars_1_1entity.html">nars.entity</a></div><div class="ttdef"><b>Definition:</b> <a href="../../d8/d59/BudgetValue_8java_source.html#l00021">BudgetValue.java:21</a></div></div>
<div class="ttc" id="namespacenars_1_1io_html"><div class="ttname"><a href="../../db/d64/namespacenars_1_1io.html">nars.io</a></div><div class="ttdef"><b>Definition:</b> <a href="../../d3/d26/ExperienceReader_8java_source.html#l00021">ExperienceReader.java:21</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Term_ae14632d1d25bcde8d6698ea0b58eb19a_html_ae14632d1d25bcde8d6698ea0b58eb19a"><div class="ttname"><a href="../../d8/db8/classnars_1_1language_1_1Term_ae14632d1d25bcde8d6698ea0b58eb19a.html#ae14632d1d25bcde8d6698ea0b58eb19a">nars.language.Term.getComplexity</a></div><div class="ttdeci">int getComplexity()</div><div class="ttdoc">The syntactic complexity, for constant automic Term, is 1. </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/df2/Term_8java_source.html#l00128">Term.java:128</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Term_ae2dba162b71bb9b806f54832249a260c_html_ae2dba162b71bb9b806f54832249a260c"><div class="ttname"><a href="../../d8/db8/classnars_1_1language_1_1Term_ae2dba162b71bb9b806f54832249a260c.html#ae2dba162b71bb9b806f54832249a260c">nars.language.Term.clone</a></div><div class="ttdeci">Object clone()</div><div class="ttdoc">Make a new Term with the same name. </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/df2/Term_8java_source.html#l00083">Term.java:83</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_html"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory.html">nars.storage.Memory</a></div><div class="ttdoc">The memory of the system. </div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00051">Memory.java:51</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Similarity_html"><div class="ttname"><a href="../../d3/d1f/classnars_1_1language_1_1Similarity.html">nars.language.Similarity</a></div><div class="ttdoc">A Statement about a Similarity relation. </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d32/Similarity_8java_source.html#l00031">Similarity.java:31</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_a4e1558986087d2202179074a3ae76ca4_html_a4e1558986087d2202179074a3ae76ca4"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a4e1558986087d2202179074a3ae76ca4.html#a4e1558986087d2202179074a3ae76ca4">nars.inference.LocalRules.inferToSym</a></div><div class="ttdeci">static void inferToSym(Sentence judgment1, Sentence judgment2, Memory memory)</div><div class="ttdoc">{<S --> P>, </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00217">LocalRules.java:217</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508_html_a26eda4f00b333b706b4e3d069fdf1508"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">nars.storage.Memory.getCurrentTask</a></div><div class="ttdeci">Task getCurrentTask()</div><div class="ttdoc">The selected Task. </div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00625">Memory.java:625</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_af0cd0f846c8a7e500840b517ab006b94_html_af0cd0f846c8a7e500840b517ab006b94"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_af0cd0f846c8a7e500840b517ab006b94.html#af0cd0f846c8a7e500840b517ab006b94">nars.inference.TruthFunctions.deduction</a></div><div class="ttdeci">static TruthValue deduction(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<S ==> M>, <M ==> P>} |- <S ==> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00108">TruthFunctions.java:108</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_ae57a195c3623dc9b8245d977adc94b4d_html_ae57a195c3623dc9b8245d977adc94b4d"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence_ae57a195c3623dc9b8245d977adc94b4d.html#ae57a195c3623dc9b8245d977adc94b4d">nars.entity.Sentence.getRevisible</a></div><div class="ttdeci">boolean getRevisible()</div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00197">Sentence.java:197</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_aec1106814819aa1c8437001c2c4bf1a3_html_aec1106814819aa1c8437001c2c4bf1a3"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory_aec1106814819aa1c8437001c2c4bf1a3.html#aec1106814819aa1c8437001c2c4bf1a3">nars.storage.Memory.singlePremiseTask</a></div><div class="ttdeci">void singlePremiseTask(Term newContent, TruthValue newTruth, BudgetValue newBudget)</div><div class="ttdoc">Shared final operations by all single-premise rules, called in StructuralRules. </div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00314">Memory.java:314</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_aeb46ba9d63958c022519607076ce1273_html_aeb46ba9d63958c022519607076ce1273"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_aeb46ba9d63958c022519607076ce1273.html#aeb46ba9d63958c022519607076ce1273">nars.inference.LocalRules.conversion</a></div><div class="ttdeci">static void conversion(Memory memory)</div><div class="ttdoc">{ </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00269">LocalRules.java:269</a></div></div>
<div class="ttc" id="classnars_1_1io_1_1Symbols_a13b034b1bca44b2f3d3c8de6d1607047_html_a13b034b1bca44b2f3d3c8de6d1607047"><div class="ttname"><a href="../../dc/d71/classnars_1_1io_1_1Symbols_a13b034b1bca44b2f3d3c8de6d1607047.html#a13b034b1bca44b2f3d3c8de6d1607047">nars.io.Symbols.JUDGMENT_MARK</a></div><div class="ttdeci">static final char JUDGMENT_MARK</div><div class="ttdef"><b>Definition:</b> <a href="../../d5/da0/Symbols_8java_source.html#l00029">Symbols.java:29</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_a21cfc2af8051142d084776d0bbc618e6_html_a21cfc2af8051142d084776d0bbc618e6"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a21cfc2af8051142d084776d0bbc618e6.html#a21cfc2af8051142d084776d0bbc618e6">nars.inference.LocalRules.revisible</a></div><div class="ttdeci">static boolean revisible(Sentence s1, Sentence s2)</div><div class="ttdoc">Check whether two sentences can be used in revision. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00075">LocalRules.java:75</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1BudgetValue_ae83b822f3bab4c1831e94d72fc770f58_html_ae83b822f3bab4c1831e94d72fc770f58"><div class="ttname"><a href="../../db/d8e/classnars_1_1entity_1_1BudgetValue_ae83b822f3bab4c1831e94d72fc770f58.html#ae83b822f3bab4c1831e94d72fc770f58">nars.entity.BudgetValue.aboveThreshold</a></div><div class="ttdeci">boolean aboveThreshold()</div><div class="ttdoc">Whether the budget should get any processing at all. </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/d59/BudgetValue_8java_source.html#l00198">BudgetValue.java:198</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_ada47dcf3767d0fb0dc24b00872edf8b3_html_ada47dcf3767d0fb0dc24b00872edf8b3"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_ada47dcf3767d0fb0dc24b00872edf8b3.html#ada47dcf3767d0fb0dc24b00872edf8b3">nars.inference.LocalRules.inferToAsym</a></div><div class="ttdeci">static void inferToAsym(Sentence asym, Sentence sym, Memory memory)</div><div class="ttdoc">{<S <-> P>, </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00248">LocalRules.java:248</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Task_html"><div class="ttname"><a href="../../dc/ddc/classnars_1_1entity_1_1Task.html">nars.entity.Task</a></div><div class="ttdoc">A task to be processed, consists of a Sentence and a BudgetValue. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d10/Task_8java_source.html#l00035">Task.java:35</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a_html_a4e4c29fc305a6741da88ce55fbf11e4a"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">nars.language.Statement.make</a></div><div class="ttdeci">static Statement make(String relation, Term subject, Term predicate, Memory memory)</div><div class="ttdoc">Make a Statement from String, called by StringParser. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00068">Statement.java:68</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_html"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement.html">nars.language.Statement</a></div><div class="ttdoc">A statement is a compound term, consisting of a subject, a predicate, and a relation symbol in betwee...</div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00033">Statement.java:33</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f_html_ab140cb553a6cf40b07093d1df283567f"><div class="ttname"><a href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">nars.entity.Task.getSentence</a></div><div class="ttdeci">Sentence getSentence()</div><div class="ttdoc">Get the sentence. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d10/Task_8java_source.html#l00099">Task.java:99</a></div></div>
<div class="ttc" id="classnars_1_1io_1_1Symbols_html"><div class="ttname"><a href="../../dc/d71/classnars_1_1io_1_1Symbols.html">nars.io.Symbols</a></div><div class="ttdoc">The ASCII symbols used in I/O. </div><div class="ttdef"><b>Definition:</b> <a href="../../d5/da0/Symbols_8java_source.html#l00026">Symbols.java:26</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e_html_ad1ded9a02cae3557948d05530cd4d37e"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">nars.entity.Sentence.getContent</a></div><div class="ttdeci">Term getContent()</div><div class="ttdoc">Get the content of the sentence. </div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00133">Sentence.java:133</a></div></div>
<div class="ttc" id="namespacenars_1_1storage_html"><div class="ttname"><a href="../../de/ddc/namespacenars_1_1storage.html">nars.storage</a></div><div class="ttdef"><b>Definition:</b> <a href="../../d6/dce/Bag_8java_source.html#l00021">Bag.java:21</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1BudgetFunctions_ac5e336432ebc7744461334f04bfd5216_html_ac5e336432ebc7744461334f04bfd5216"><div class="ttname"><a href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac5e336432ebc7744461334f04bfd5216.html#ac5e336432ebc7744461334f04bfd5216">nars.inference.BudgetFunctions.revise</a></div><div class="ttdeci">static BudgetValue revise(TruthValue tTruth, TruthValue bTruth, TruthValue truth, boolean feedbackToLinks, Memory memory)</div><div class="ttdoc">Evaluate the quality of a revision, then de-prioritize the premises. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/d4e/BudgetFunctions_8java_source.html#l00118">BudgetFunctions.java:118</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_a3ecf859c238ad7f0c44c45e3e5df0081_html_a3ecf859c238ad7f0c44c45e3e5df0081"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a3ecf859c238ad7f0c44c45e3e5df0081.html#a3ecf859c238ad7f0c44c45e3e5df0081">nars.inference.LocalRules.trySolution</a></div><div class="ttdeci">static void trySolution(Sentence belief, Task task, Memory memory)</div><div class="ttdoc">Check if a Sentence provide a better answer to a Question or Goal. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00118">LocalRules.java:118</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_html"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules.html">nars.inference.LocalRules</a></div><div class="ttdoc">Directly process a task by a oldBelief, with only two Terms in both. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00038">LocalRules.java:38</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1TruthValue_aa5ffcde3ae611b087ba7fdd4cd67b216_html_aa5ffcde3ae611b087ba7fdd4cd67b216"><div class="ttname"><a href="../../d3/db8/classnars_1_1entity_1_1TruthValue_aa5ffcde3ae611b087ba7fdd4cd67b216.html#aa5ffcde3ae611b087ba7fdd4cd67b216">nars.entity.TruthValue.getExpectation</a></div><div class="ttdeci">float getExpectation()</div><div class="ttdoc">Calculate the expectation value of the truth value. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/de7/TruthValue_8java_source.html#l00077">TruthValue.java:77</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Task_a091f9ec3bdacfd6741f767cb62b14c0f_html_a091f9ec3bdacfd6741f767cb62b14c0f"><div class="ttname"><a href="../../dc/ddc/classnars_1_1entity_1_1Task_a091f9ec3bdacfd6741f767cb62b14c0f.html#a091f9ec3bdacfd6741f767cb62b14c0f">nars.entity.Task.getContent</a></div><div class="ttdeci">Term getContent()</div><div class="ttdoc">Directly get the content of the sentence. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d10/Task_8java_source.html#l00108">Task.java:108</a></div></div>
<div class="ttc" id="namespacenars_html"><div class="ttname"><a href="../../d7/d81/namespacenars.html">nars</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Task_ae0fc96866e544c3dda5a87ea5c806fc3_html_ae0fc96866e544c3dda5a87ea5c806fc3"><div class="ttname"><a href="../../dc/ddc/classnars_1_1entity_1_1Task_ae0fc96866e544c3dda5a87ea5c806fc3.html#ae0fc96866e544c3dda5a87ea5c806fc3">nars.entity.Task.getParentBelief</a></div><div class="ttdeci">Sentence getParentBelief()</div><div class="ttdoc">Get the parent belief of a task. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d10/Task_8java_source.html#l00176">Task.java:176</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_html"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">nars.entity.Sentence</a></div><div class="ttdoc">A Sentence is an abstract class, mainly containing a Term, a TruthValue, and a Stamp. </div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00031">Sentence.java:31</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_a22620614c797410623291399bae01a0b_html_a22620614c797410623291399bae01a0b"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a22620614c797410623291399bae01a0b.html#a22620614c797410623291399bae01a0b">nars.inference.TruthFunctions.revision</a></div><div class="ttdeci">static TruthValue revision(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<S ==> P>, <S ==> P>} |- <S ==> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00085">TruthFunctions.java:85</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_a26cbb4acec5bb2c23a048d7deba4051d_html_a26cbb4acec5bb2c23a048d7deba4051d"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory_a26cbb4acec5bb2c23a048d7deba4051d.html#a26cbb4acec5bb2c23a048d7deba4051d">nars.storage.Memory.report</a></div><div class="ttdeci">void report(Sentence sentence, boolean input)</div><div class="ttdoc">Display input/output sentence in the output channels. </div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00464">Memory.java:464</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f_html_ad85f45a7858737445d5158801774ff5f"><div class="ttname"><a href="../../d8/db8/classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f.html#ad85f45a7858737445d5158801774ff5f">nars.language.Term.equals</a></div><div class="ttdeci">boolean equals(Object that)</div><div class="ttdoc">Equal terms have identical name, though not necessarily the same reference. </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/df2/Term_8java_source.html#l00094">Term.java:94</a></div></div>
<div class="ttc" id="classnars_1_1io_1_1Symbols_a9ff625a6eaec1b710eaec490ee8fc549_html_a9ff625a6eaec1b710eaec490ee8fc549"><div class="ttname"><a href="../../dc/d71/classnars_1_1io_1_1Symbols_a9ff625a6eaec1b710eaec490ee8fc549.html#a9ff625a6eaec1b710eaec490ee8fc549">nars.io.Symbols.VAR_QUERY</a></div><div class="ttdeci">static final char VAR_QUERY</div><div class="ttdef"><b>Definition:</b> <a href="../../d5/da0/Symbols_8java_source.html#l00035">Symbols.java:35</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Variable_a2770bbc76b3aac48f49a1c15aaedab1b_html_a2770bbc76b3aac48f49a1c15aaedab1b"><div class="ttname"><a href="../../de/da5/classnars_1_1language_1_1Variable_a2770bbc76b3aac48f49a1c15aaedab1b.html#a2770bbc76b3aac48f49a1c15aaedab1b">nars.language.Variable.unify</a></div><div class="ttdeci">static boolean unify(char type, Term t1, Term t2)</div><div class="ttdoc">To unify two terms. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/de0/Variable_8java_source.html#l00109">Variable.java:109</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5_html_ac3df7e788b7a6e2b348d2ae7da7936c5"><div class="ttname"><a href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">nars.inference.BudgetFunctions.forward</a></div><div class="ttdeci">static BudgetValue forward(TruthValue truth, Memory memory)</div><div class="ttdoc">Forward inference result and adjustment. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/d4e/BudgetFunctions_8java_source.html#l00248">BudgetFunctions.java:248</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1BudgetFunctions_html"><div class="ttname"><a href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">nars.inference.BudgetFunctions</a></div><div class="ttdoc">Budget functions for resources allocation. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/d4e/BudgetFunctions_8java_source.html#l00031">BudgetFunctions.java:31</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1TruthValue_html"><div class="ttname"><a href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">nars.entity.TruthValue</a></div><div class="ttdoc">Frequency and confidence. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/de7/TruthValue_8java_source.html#l00028">TruthValue.java:28</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_aa0cec63b98350a34c10513f3efeaff86_html_aa0cec63b98350a34c10513f3efeaff86"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory_aa0cec63b98350a34c10513f3efeaff86.html#aa0cec63b98350a34c10513f3efeaff86">nars.storage.Memory.activatedTask</a></div><div class="ttdeci">void activatedTask(BudgetValue budget, Sentence sentence, Sentence candidateBelief)</div><div class="ttdoc">Activated task called in MatchingRules.trySolution and Concept.processGoal. </div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00237">Memory.java:237</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Task_a63d100ab04dafaea220b3c1125b782e6_html_a63d100ab04dafaea220b3c1125b782e6"><div class="ttname"><a href="../../dc/ddc/classnars_1_1entity_1_1Task_a63d100ab04dafaea220b3c1125b782e6.html#a63d100ab04dafaea220b3c1125b782e6">nars.entity.Task.getBestSolution</a></div><div class="ttdeci">Sentence getBestSolution()</div><div class="ttdoc">Get the best-so-far solution for a Question or Goal. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d10/Task_8java_source.html#l00158">Task.java:158</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_a7d95d60caaf4c895559182a7eb2ff71e_html_a7d95d60caaf4c895559182a7eb2ff71e"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence_a7d95d60caaf4c895559182a7eb2ff71e.html#a7d95d60caaf4c895559182a7eb2ff71e">nars.entity.Sentence.isJudgment</a></div><div class="ttdeci">boolean isJudgment()</div><div class="ttdoc">Distinguish Judgment from Goal ("instanceof Judgment" doesn&#39;t work) </div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00181">Sentence.java:181</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Equivalence_ad5069483330bc875fbb48a1e992f7bf7_html_ad5069483330bc875fbb48a1e992f7bf7"><div class="ttname"><a href="../../d1/d8b/classnars_1_1language_1_1Equivalence_ad5069483330bc875fbb48a1e992f7bf7.html#ad5069483330bc875fbb48a1e992f7bf7">nars.language.Equivalence.make</a></div><div class="ttdeci">static Equivalence make(Term subject, Term predicate, Memory memory)</div><div class="ttdoc">Try to make a new compound from two components. </div><div class="ttdef"><b>Definition:</b> <a href="../../d3/dcc/Equivalence_8java_source.html#l00067">Equivalence.java:67</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Task_a0dfdf9a597e57b5cf70d88f954ac7a3f_html_a0dfdf9a597e57b5cf70d88f954ac7a3f"><div class="ttname"><a href="../../dc/ddc/classnars_1_1entity_1_1Task_a0dfdf9a597e57b5cf70d88f954ac7a3f.html#a0dfdf9a597e57b5cf70d88f954ac7a3f">nars.entity.Task.isInput</a></div><div class="ttdeci">boolean isInput()</div><div class="ttdoc">Check if a Task is a direct input. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d10/Task_8java_source.html#l00126">Task.java:126</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_a3664d0b53eca935536d60cd0e3a13256_html_a3664d0b53eca935536d60cd0e3a13256"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence_a3664d0b53eca935536d60cd0e3a13256.html#a3664d0b53eca935536d60cd0e3a13256">nars.entity.Sentence.containQueryVar</a></div><div class="ttdeci">boolean containQueryVar()</div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00193">Sentence.java:193</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Equivalence_html"><div class="ttname"><a href="../../d1/d8b/classnars_1_1language_1_1Equivalence.html">nars.language.Equivalence</a></div><div class="ttdoc">A Statement about an Equivalence relation. </div><div class="ttdef"><b>Definition:</b> <a href="../../d3/dcc/Equivalence_8java_source.html#l00031">Equivalence.java:31</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Term_html"><div class="ttname"><a href="../../d8/db8/classnars_1_1language_1_1Term.html">nars.language.Term</a></div><div class="ttdoc">Term is the basic component of Narsese, and the object of processing in NARS. </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/df2/Term_8java_source.html#l00040">Term.java:40</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_ae878f1b2fff31ef78b7916bde1b939b3_html_ae878f1b2fff31ef78b7916bde1b939b3"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_ae878f1b2fff31ef78b7916bde1b939b3.html#ae878f1b2fff31ef78b7916bde1b939b3">nars.inference.LocalRules.convertRelation</a></div><div class="ttdeci">static void convertRelation(Memory memory)</div><div class="ttdoc">{<S --> P>} |- <S <-> P> {<S <-> P>} |- <S --> P> Switch between Inheritance/Implication and Similari...</div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00283">LocalRules.java:283</a></div></div>
<div class="ttc" id="namespacenars_1_1language_html"><div class="ttname"><a href="../../d0/d72/namespacenars_1_1language.html">nars.language</a></div><div class="ttdef"><b>Definition:</b> <a href="../../d5/d0e/CompoundTerm_8java_source.html#l00021">CompoundTerm.java:21</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_ae8945611915519f50ab3392c9168b170_html_ae8945611915519f50ab3392c9168b170"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ae8945611915519f50ab3392c9168b170.html#ae8945611915519f50ab3392c9168b170">nars.inference.TruthFunctions.reduceConjunction</a></div><div class="ttdeci">static TruthValue reduceConjunction(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{(–, (&&, A, B)), B} |- (–, A) </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00407">TruthFunctions.java:407</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Variable_a25dcc4d5882131d679903f93d41420c9_html_a25dcc4d5882131d679903f93d41420c9"><div class="ttname"><a href="../../de/da5/classnars_1_1language_1_1Variable_a25dcc4d5882131d679903f93d41420c9.html#a25dcc4d5882131d679903f93d41420c9">nars.language.Variable.containVarQuery</a></div><div class="ttdeci">static boolean containVarQuery(String n)</div><div class="ttdoc">Check whether a string represent a name of a term that contains a query variable. ...</div><div class="ttdef"><b>Definition:</b> <a href="../../d2/de0/Variable_8java_source.html#l00089">Variable.java:89</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_a93af32adec92cf57671c32e9ccc2dffc_html_a93af32adec92cf57671c32e9ccc2dffc"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a93af32adec92cf57671c32e9ccc2dffc.html#a93af32adec92cf57671c32e9ccc2dffc">nars.inference.LocalRules.matchReverse</a></div><div class="ttdeci">static void matchReverse(Memory memory)</div><div class="ttdoc">The task and belief match reversely. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00171">LocalRules.java:171</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1TruthValue_a68ca7d92e9ea20d2a9a9f578ad7b681c_html_a68ca7d92e9ea20d2a9a9f578ad7b681c"><div class="ttname"><a href="../../d3/db8/classnars_1_1entity_1_1TruthValue_a68ca7d92e9ea20d2a9a9f578ad7b681c.html#a68ca7d92e9ea20d2a9a9f578ad7b681c">nars.entity.TruthValue.getConfidence</a></div><div class="ttdeci">float getConfidence()</div><div class="ttdoc">Get the confidence value. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/de7/TruthValue_8java_source.html#l00069">TruthValue.java:69</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b_html_aae366ea198c2340fef786120d5c2163b"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">nars.storage.Memory.getCurrentBelief</a></div><div class="ttdeci">Sentence getCurrentBelief()</div><div class="ttdoc">The selected belief. </div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00647">Memory.java:647</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70_html_a077b38e451ff6e4217bdc2ff0bb08e70"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">nars.storage.Memory.doublePremiseTask</a></div><div class="ttdeci">void doublePremiseTask(Term newContent, TruthValue newTruth, BudgetValue newBudget)</div><div class="ttdoc">Shared final operations by all double-premise rules, called from the rules except StructuralRules...</div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00280">Memory.java:280</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_a721f626ab83f34dc2e6858a4eede7102_html_a721f626ab83f34dc2e6858a4eede7102"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence_a721f626ab83f34dc2e6858a4eede7102.html#a721f626ab83f34dc2e6858a4eede7102">nars.entity.Sentence.clone</a></div><div class="ttdeci">Object clone()</div><div class="ttdoc">Clone the Sentence. </div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00122">Sentence.java:122</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Variable_html"><div class="ttname"><a href="../../de/da5/classnars_1_1language_1_1Variable.html">nars.language.Variable</a></div><div class="ttdoc">A variable term, which does not correspond to a concept. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/de0/Variable_8java_source.html#l00030">Variable.java:30</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1BudgetValue_html"><div class="ttname"><a href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">nars.entity.BudgetValue</a></div><div class="ttdoc">A triple of priority (current), durability (decay), and quality (long-term average). </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/d59/BudgetValue_8java_source.html#l00031">BudgetValue.java:31</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_aac1c92950f50edd04d12229a8c992987_html_aac1c92950f50edd04d12229a8c992987"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_aac1c92950f50edd04d12229a8c992987.html#aac1c92950f50edd04d12229a8c992987">nars.inference.LocalRules.match</a></div><div class="ttdeci">static void match(Task task, Sentence belief, Memory memory)</div><div class="ttdoc">The task and belief have the same content. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00053">LocalRules.java:53</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1LocalRules_a91eadfda9f647cd8e799b4f982e14fca_html_a91eadfda9f647cd8e799b4f982e14fca"><div class="ttname"><a href="../../d4/de9/classnars_1_1inference_1_1LocalRules_a91eadfda9f647cd8e799b4f982e14fca.html#a91eadfda9f647cd8e799b4f982e14fca">nars.inference.LocalRules.solutionQuality</a></div><div class="ttdeci">static float solutionQuality(Sentence problem, Sentence solution)</div><div class="ttdoc">Evaluate the quality of the judgment as a solution to a problem. </div><div class="ttdef"><b>Definition:</b> <a href="../../d0/db7/LocalRules_8java_source.html#l00148">LocalRules.java:148</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5_html_ace4f80751d303c613e467163913bebf5"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5.html#ace4f80751d303c613e467163913bebf5">nars.language.Statement.getSubject</a></div><div class="ttdeci">Term getSubject()</div><div class="ttdoc">Return the first component of the statement. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00229">Statement.java:229</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Similarity_ae72436d78c25d4735b4201d773dd1901_html_ae72436d78c25d4735b4201d773dd1901"><div class="ttname"><a href="../../d3/d1f/classnars_1_1language_1_1Similarity_ae72436d78c25d4735b4201d773dd1901.html#ae72436d78c25d4735b4201d773dd1901">nars.language.Similarity.make</a></div><div class="ttdeci">static Similarity make(Term subject, Term predicate, Memory memory)</div><div class="ttdoc">Try to make a new compound from two components. </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d32/Similarity_8java_source.html#l00068">Similarity.java:68</a></div></div>
</div><!-- fragment --></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="../../dir_ed82ebcd34e530b246c6fd9032262140.html">aruntime</a></li><li class="navelem"><a class="el" href="../../dir_19496ddff8e6c0f2b6654287ecb1a472.html">src</a></li><li class="navelem"><a class="el" href="../../dir_db9c5934f797909f7296c2c2017f7fc9.html">main</a></li><li class="navelem"><a class="el" href="../../dir_6d74390eb6d6287951075e525bcb9bed.html">java</a></li><li class="navelem"><a class="el" href="../../dir_51a24984472456d47100350cd31f9a7c.html">nars</a></li><li class="navelem"><a class="el" href="../../dir_ee323373cf7c53e5489dea03632cbb1d.html">inference</a></li><li class="navelem"><a class="el" href="../../d0/db7/LocalRules_8java.html">LocalRules.java</a></li>
    <li class="footer">Generated on Sun Jan 10 2016 18:03:58 for opennars by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="../../doxygen.png" alt="doxygen"/></a> 1.8.9.1 </li>
  </ul>
</div>
</body>
</html>
